package com.csproj.basic.service.dto;


import com.csproj.basic.domain.ElectronicLockMessage;

import io.swagger.annotations.ApiModelProperty;

import javax.persistence.Column;
import javax.validation.constraints.NotNull;

import java.io.Serializable;
import java.time.ZonedDateTime;
import java.time.format.DateTimeFormatter;
import java.util.Objects;

/**
 * A DTO for the ElectronicLockMessage entity.
 */
public class ElectronicLockMessageDTO implements Serializable {
    private String id;

    private String elNumber;

    public String getElNumber() {
        return elNumber;
    }
    public void setElNumber(String el_number) {
        this.elNumber = elNumber;
    }

    private String header;

    public String getHeader() {
        return header;
    }
    public void setHeader(String header) {
        this.header = header;
    }

    private String len;

    public String getLen() {
        return len;
    }
    public void setLen(String len) {
        this.len = len;
    }

    private String mId;

    public String getMid() {
        return mId;
    }
    public void setMid(String mId) {
        this.mId = mId;
    }

    private Boolean lockStickStatus;
    private String dispatchId;

    public String getDispatchId() {
        return dispatchId;
    }

    public void setDispatchId(String dispatchId) {
        this.dispatchId = dispatchId;
    }


    public Boolean getLockStickStatus() {
        return lockStickStatus;
    }
    public void setLockStickStatus(Boolean lockStickStatus) {
        this.lockStickStatus = lockStickStatus;
    }

    private Boolean outerStatus;

    public Boolean getOuterStatus() {
        return outerStatus;
    }
    public void setOuterStatus(Boolean outerStatus) {
        this.outerStatus = outerStatus;
    }

    private Boolean gpsStatus;

    public Boolean getGpsStatus() {
        return gpsStatus;
    }
    public void setGpsStatus(Boolean gpsStatus) {
        this.gpsStatus = gpsStatus;
    }

    private Boolean isLocked;

    public Boolean getIsLocked() {
        return isLocked;
    }
    public void setIsLocked(Boolean isLocked) {
        this.isLocked = isLocked;
    }

    private Boolean isOpen;

    public Boolean getIsOpen() {
        return isOpen;
    }
    public void setIsOpen(Boolean isOpen) {
        this.isOpen = isOpen;
    }

    private float latitude;

    public float getLatitude() {
        return latitude;
    }
    public void setLatitude(float latitude) {
        this.latitude = latitude;
    }

    private float longitude ;

    public float getLongitude() {
        return longitude;
    }
    public void setLongitude(float longitude) {
        this.longitude = longitude;
    }

    private int volt;

    public float getVolt() {
        return volt;
    }
    public void setVolt(int volt) {
        this.volt = volt;
    }

    private float speed;

    public float getSpeed() {
        return speed;
    }
    public void setSpeed(float speed) {
        this.speed = speed;
    }

    private float direction;

    public float getDirection() {
        return direction;
    }
    public void setDirection(float direction) {
        this.direction = direction;
    }


    private float altitude;

    public float getAltitude() {
        return altitude;
    }
    public void setAltitude(float altitude) {
        this.altitude = altitude;
    }

    private float hight;

    public float getHight() {
        return hight;
    }
    public void setHight(float hight) {
        this.hight = hight;
    }

    private int gpsStarNumber;

    public float getGpsStarNumber() {
        return gpsStarNumber;
    }
    public void setGpsStarNumber(int gpsStarNumber) {
        this.gpsStarNumber = gpsStarNumber;
    }

    private String gpsStarIds;

    public String getGpsStarIds() {
        return gpsStarIds;
    }

    public void setGpsStarIds(String gpsStarIds) {
        this.gpsStarIds = gpsStarIds;
    }

    private int bdStarNumber;

    public float getBdStarNumber() {
        return bdStarNumber;
    }

    public void setBdStarNumber(int bdStarNumber) {
        this.bdStarNumber = bdStarNumber;
    }

    private String bdStarIds;

    public String getBdStarIds() {
        return bdStarIds;
    }

    public void setBdStarIds(String bdStarIds) {
        this.bdStarIds = bdStarIds;
    }

    private int gsmSignal;

    public float getGsmSignal() {
        return gsmSignal;
    }

    public void setGsmSignal(int gsmSignal) {
        this.gsmSignal = gsmSignal;
    }

    private int isMoving;

    public float getIsMoving() {
        return isMoving;
    }

    public void setIsMoving(int isMoving) {
        this.isMoving = isMoving;
    }

    private ZonedDateTime time;

    public ZonedDateTime getTime() {
        return time;
    }
    
    public void setTime(ZonedDateTime time) {
        this.time = time;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    @Override
    public int hashCode() {
        return Objects.hashCode(getId());
    }

    @Override
    public String toString() {
    	DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
        return "ElectronicLockMessage{" +
                "ELnumber=" + getElNumber() +
                ", is_locked='" + getIsLocked() + "'" +
                ", is_open='" + getIsOpen() + "'" +
                ", latitude='" + getLatitude() + "'" +
                ", longitude='" + getLongitude() + "'" +
                ", altitude='" + getAltitude() + "'" +
                ", spped='" + getSpeed() + "'" +
                ", hight='" + getHight() + "'" +
                ", direction='" + getDirection() + "'" +
                ", gps_star_number='" + getGpsStarNumber() + "'" +
                ", gps_star_ids='" + getGpsStarIds() + "'" +
                ", bd_star_number='" + getBdStarNumber() + "'" +
                ", bd_star_ids='" + getBdStarIds() + "'" +
                ", gps_signal='" + getGsmSignal() + "'" +
                ", volt='" + getVolt() + "'" +
                ", time='" + getTime().format(formatter) + "'" +
                "}";
    }
}
